#pragma once

#include "Property/EditorPropertyModel.h"
#include "Pages/EditorPageModel.h"
#include "Math/Vec3.h"
#include "EditorNodeRotationPropertyModel.m.h"

class RSceneNode;


RCLASS()
class REditorNodeRotationPropertyOperation : public REditorPageOperation
{
    ROBJECT

public:

    void ChangeValue(
        TSharedObjectPtr<RSceneNode> InNode,
        const SVec3& InOldValue,
        const SVec3& InNewValue
        );
protected:

    TSharedObjectPtr<RSceneNode> Node;
    SVec3 OldValue;
    SVec3 NewValue;

};

RCLASS(ExtraHeader="Scene/SceneNode.h")
class REditorNodeRotationPropertyModel : public REditorPropertyModel
{
    ROBJECT

public:

    static TSharedObjectPtr<REditorNodeRotationPropertyModel> Create(
        TSharedObjectPtr<RSceneNode> InNode,
        RObject* InParent
        );

    RFIELD()
    TSharedObjectPtr<RSceneNode> Node;

    float GetX() const;
    void SetX(float InX);

    float GetY() const;
    void SetY(float InY);

    float GetZ() const;
    void SetZ(float InZ);

};